package me.send.data.service.service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import me.send.business.base.Pager;
import me.send.data.service.mapper.BrokerEvaluateMapper;
import me.send.data.service.pojo.BrokerEvaluate;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class BrokerEvaluateService {

	@Autowired
	private BrokerEvaluateMapper brokerEvaluateMapper;
	
	public List<BrokerEvaluate> list(String user_phone,String broker_phone,String start, String end,Pager page) {
    	Map<String, Object> parameter = new HashMap<String, Object>();
    	parameter.put("user_phone", user_phone);
    	parameter.put("broker_phone", broker_phone);
    	parameter.put("start", start);
    	parameter.put("end", end);
    	parameter.put("page", page);
    	List<BrokerEvaluate> rows = brokerEvaluateMapper.list(parameter);
    	return rows;
    }
	public Integer count(String user_phone,String broker_phone,String start, String end) {
		Map<String, Object> parameter = new HashMap<String, Object>();
		parameter.put("user_phone", user_phone);
		parameter.put("broker_phone", broker_phone);
		parameter.put("start", start);
		parameter.put("end", end);
		Integer rows = brokerEvaluateMapper.count(parameter);
		return rows;
	}
	
	
    
	

}
